package org.budo.weixin.symbol;

import org.budo.support.lang.util.StringUtil;

/**
 * 微信标签工具
 * @author li
 * @version 1 (2015年7月31日 下午3:30:07)
 * @since Java7
 */
public class WeixinSymbolUtil {
    /**
     * 将表情替换为文本
     */
    public static String replaceSymbolToText(String content) {
        if (StringUtil.isEmpty(content)) {
            return content;
        }
        content = content.replace("/::)", "[微笑]");
        content = content.replace("/::~", "[撇嘴]");
        content = content.replace("/::B", "[色]");
        content = content.replace("/::|", "[发呆]");
        content = content.replace("/:8-)", "[得意]");
        content = content.replace("/::<", "[流泪]");
        content = content.replace("/::$", "[害羞]");
        content = content.replace("/::X", "[闭嘴]");
        content = content.replace("/::'(", "[大哭]");
        content = content.replace("/::-|", "[尴尬]");
        content = content.replace("/::@", "[发怒]");
        content = content.replace("/::P", "[调皮]");
        content = content.replace("/::D", "[呲牙]");
        content = content.replace("/::O", "[惊讶]");
        content = content.replace("/::(", "[难过]");
        content = content.replace("/:,@o", "[傲慢]");
        content = content.replace("/::,@", "[悠闲]");
        content = content.replace("/:xx", "[敲打]");
        content = content.replace("/:,@f", "[奋斗]");
        content = content.replace("/:?", "[疑问]");
        content = content.replace("/:|-)", "[困]");
        content = content.replace("/:<@", "[左哼哼]");
        content = content.replace("/:@>", "[右哼哼]");
        content = content.replace("/:coffee", "[咖啡]");
        content = content.replace("/:break", "[心碎]");
        content = content.replace("/:cake", "[蛋糕]");
        content = content.replace("/:@@", "[拳头]");
        content = content.replace("/:love", "[爱情]");
        content = content.replace("/:<L>", "[飞吻]");
        return content;
    }
}